package com.rjj.wlqq.wxpay.wxpay.entity;

/**
 * @author r
 * @date 2021/1/20 17:52
 * <p>
 * 微信配置的实体
 */
public class Wx
{
    private String appId;
    private String mchId;
    private String key;
    private String pathFile;

    Wx(String appId, String mchId, String key, String pathFile)
    {
        this.appId = appId;
        this.mchId = mchId;
        this.key = key;
        this.pathFile = pathFile;
    }

    public static WxBuilder builder()
    {
        return new WxBuilder();
    }

    public String getAppId()
    {
        return this.appId;
    }

    public String getMchId()
    {
        return this.mchId;
    }

    public String getKey()
    {
        return this.key;
    }

    public String getPathFile()
    {
        return this.pathFile;
    }

    public void setAppId(String appId)
    {
        this.appId = appId;
    }

    public void setMchId(String mchId)
    {
        this.mchId = mchId;
    }

    public void setKey(String key)
    {
        this.key = key;
    }

    public void setPathFile(String pathFile)
    {
        this.pathFile = pathFile;
    }


    public static class WxBuilder
    {
        private String appId;
        private String mchId;
        private String key;
        private String pathFile;

        WxBuilder()
        {
        }

        public WxBuilder appId(String appId)
        {
            this.appId = appId;
            return this;
        }

        public WxBuilder mchId(String mchId)
        {
            this.mchId = mchId;
            return this;
        }

        public WxBuilder key(String key)
        {
            this.key = key;
            return this;
        }

        public WxBuilder pathFile(String pathFile)
        {
            this.pathFile = pathFile;
            return this;
        }

        public Wx build()
        {
            return new Wx(appId, mchId, key, pathFile);
        }

        @Override
        public String toString()
        {
            return "Wx.WxBuilder(appId=" + this.appId + ", mchId=" + this.mchId + ", key=" + this.key + ", pathFile=" + this.pathFile + ")";
        }
    }

}
